<template>
    <div class="main">
        <h1>this is login page</h1>
    </div>
</template>
<script>
export default {
    beforeRouteEnter(to, from, next){
        if(from.name === 'test'){
            next();
        }else{
            // alert('错误，只能从test页面进入');
            next();
        }
    },
    mounted(){
       
    }
    
}
</script>

<style lang="scss">
    @import '@/assets/styles/normal.scss';
    .todo{
      height: 100%;
      width: 100%;
      @include flexCol;
    }
    .main{
        flex-grow: 1;
        background-color: #fff;
    }
</style>